/**
 * Created by Administrator on 2017/6/28 0028.
 */
    $('#pages-login-btn').click(function () {
        console.log('111')
        var username= $('#pages-login-name').val();
        var passwd= $('#pages-login-pwd').val();
        var rememberTime = 0;
        if($('#pages-login-remember').prop('checked')){
            var rememberTime = 10;
        }
        $.ajax({
            url:"/",
            type:'POST',
            data:{'username':username,'password':passwd,'rememberTime':rememberTime},    //提交的数据
            success:function (data) {
                var obj = JSON.parse(data);
                if(obj.login == true){
                    window.location.href = "/users/";
                }
            }
        })
    }
);